import request from "@/utils/request"

//列表查询
export const queryStuApi = 
    (name,degree,clazzId,page,pageSize) => 
    request.get(`/students?name=${name}&degree=${degree}&clazzId=${clazzId}&page=${page}&pageSize=${pageSize}`)


// 新增学员信息
export const addStuApi = (students) => request.post('/students',students)


// 编辑班级信息
// 1.根据id查询班级信息
export const queryStuByIdApi = (id) => request.get(`/students/${id}`)


// 2.编辑信息
export const updateStuApi = (students) => request.put('/students',students)


// 删除数据
// 根据id删除单个班级
export const delStuByIdApi = (ids) => request.delete(`/students/${ids}`)

// 查询全部班级
// export const findAllClazzApi = () => request.get('/clazzs/list')

// 违纪处理 
export const violationStuApi = (id,score) => request.put(`/students/violation/${id}/${score}`)
